package org.example.springcloud.feign;

import feign.Param;
import feign.RequestLine;
import org.example.config.FeignClient01Config;
import org.example.config.FeignClient02Config;
import org.example.springcloud.pojo.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(name = "123123-user",
    url = "http://localhost:10001/",
        configuration = FeignClient02Config.class
)
public interface FeignClient02 {
//    @GetMapping("/user/{id}")
    @GetMapping("/eureka/apps/{serviceName}")
    String getServiceName(@PathVariable("serviceName") String serviceName); //使用RequestLine时，必须使用Param注解
}
